<?php if(Yii::app()->user->hasFlash('contact')): ?>

<div class="flash-success">
  <?php echo Yii::app()->user->getFlash('contact'); ?>
</div>

<?php else: ?>

<div id="contact_form" class="form">
<h1><?php echo Yii::t('msg', 'contactUs');?></h1>
<?php $form=$this->beginWidget('CActiveForm', array(
  'id'=>'contact-form',
  'enableClientValidation'=>true,
  'clientOptions'=>array(
    'validateOnSubmit'=>true,
  ),
)); ?>

  <?php echo $form->errorSummary($model); ?>

  <div class="name">
    <?php echo $form->labelEx($model,'name'); ?>
    <?php echo $form->textField($model,'name'); ?>
    <?php echo $form->error($model,'name'); ?>
  </div>

  <div class="surname">
    <?php echo $form->labelEx($model,'surname'); ?>
    <?php echo $form->textField($model,'surname'); ?>
    <?php echo $form->error($model,'surname'); ?>
  </div>

  <div class="row">
    <?php echo $form->labelEx($model,'email'); ?>
    <?php echo $form->textField($model,'email'); ?>
    <?php echo $form->error($model,'email'); ?>
  </div>

  <div class="row">
    <?php echo $form->labelEx($model,'subject'); ?>
    <?php echo $form->textField($model,'subject',array('size'=>60,'maxlength'=>128)); ?>
    <?php echo $form->error($model,'subject'); ?>
  </div>

  <div class="row">
    <?php echo $form->labelEx($model,'body'); ?>
    <?php echo $form->textArea($model,'body',array('rows'=>6, 'cols'=>50)); ?>
    <?php echo $form->error($model,'body'); ?>
  </div>

  <?php $this->widget('application.extensions.recaptcha.EReCaptcha', 
   array('model'=>$model, 'attribute'=>'verifyCode',
         'theme'=>'white', 'language'=>'es_ES', 
         'publicKey'=>'6Ldm19cSAAAAADYyO1jjVADYirrgijQjBx02dLfu')) ?>
  <?php echo CHtml::error($model, 'verifyCode'); ?>

  <div class="row buttons">
    <?php echo CHtml::submitButton('Submit'); ?>
  </div>

<?php $this->endWidget(); ?>

</div><!-- form -->

<div id="address">
  <h2><?php echo Yii::t('msg', 'address');?></h2>
  <div>
    <?php echo $data['address'];?>
  </div>
  <div class="phone">
    <p><?php echo Yii::t('msg', 'tel');?> <?php echo $data['tel'];?></p>
    <p><?php echo Yii::t('msg', 'fax');?> <?php echo $data['fax'];?></p>
  </div>
  <div class="email">
    <p><?php echo $data['email_sale'];?></p>
  </div>
  <div id="map">

<div class="map_google">
<iframe width="450" height="350" frameborder="0" scrolling="no" marginheight="0" marginwidth="0" src="https://maps.google.com/maps?f=q&amp;source=s_q&amp;hl=en&amp;geocode=&amp;q=%E0%B8%9E%E0%B8%AB%E0%B8%A5%E0%B9%82%E0%B8%A2%E0%B8%98%E0%B8%B4%E0%B8%99+34+%E0%B8%81%E0%B8%A3%E0%B8%B8%E0%B8%87%E0%B9%80%E0%B8%97%E0%B8%9E%E0%B8%A1%E0%B8%AB%E0%B8%B2%E0%B8%99%E0%B8%84%E0%B8%A3+%E0%B8%9B%E0%B8%A3%E0%B8%B0%E0%B9%80%E0%B8%97%E0%B8%A8%E0%B9%84%E0%B8%97%E0%B8%A2&amp;aq=&amp;sll=13.837892,100.581229&amp;sspn=0.010709,0.017788&amp;ie=UTF8&amp;hq=&amp;hnear=Soi+Sena+Nikhom+2,+Chatuchak,+Bangkok+10900,+Thailand&amp;ll=13.837892,100.581229&amp;spn=0.010709,0.017788&amp;t=m&amp;z=14&amp;output=embed"></iframe><br /><small><a href="https://maps.google.com/maps?f=q&amp;source=embed&amp;hl=en&amp;geocode=&amp;q=%E0%B8%9E%E0%B8%AB%E0%B8%A5%E0%B9%82%E0%B8%A2%E0%B8%98%E0%B8%B4%E0%B8%99+34+%E0%B8%81%E0%B8%A3%E0%B8%B8%E0%B8%87%E0%B9%80%E0%B8%97%E0%B8%9E%E0%B8%A1%E0%B8%AB%E0%B8%B2%E0%B8%99%E0%B8%84%E0%B8%A3+%E0%B8%9B%E0%B8%A3%E0%B8%B0%E0%B9%80%E0%B8%97%E0%B8%A8%E0%B9%84%E0%B8%97%E0%B8%A2&amp;aq=&amp;sll=13.837892,100.581229&amp;sspn=0.010709,0.017788&amp;ie=UTF8&amp;hq=&amp;hnear=Soi+Sena+Nikhom+2,+Chatuchak,+Bangkok+10900,+Thailand&amp;ll=13.837892,100.581229&amp;spn=0.010709,0.017788&amp;t=m&amp;z=14" style="color:#0000FF;text-align:left">View Larger Map</a></small>
</div>
<!-- Google Map-->
</div>
</div>


<?php endif; ?>